package com.cskaoyan.bean.vo.back.configmanagement;

import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.DecimalMax;
import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;


/**
 * 商场配置
 *
 * @author 李然
 * @date 2022/10/12
 */
@NoArgsConstructor
@Data
public class MallConfigVo {

    /**
     "market_mall_longitude": "121.587860",
     "market_mall_latitude": "31.201900",
     "market_mall_address": "qweqq",
     "market_mall_qq": "1231231",
     "market_mall_phone": "021-xxxx-xxxxass",
     "market_mall_name": "market"
     */

//    地理坐标经纬度
    @NotNull
    @DecimalMin(value = "-180", message = "必须为数字且不能小于-180")
    @DecimalMax(value = "180", message = "必须为数字且不能大于180")
    private String market_mall_longitude;
    @NotNull
    @DecimalMin(value = "-90", message = "必须为数字且不能小于-90")
    @DecimalMax(value = "90", message = "必须为数字且不能大于90")
    private String market_mall_latitude;
    @NotNull
    private String market_mall_address;
    @NotNull
    @Pattern(regexp = "[1-9][0-9]{4,14}", message = "qq格式: 首位不能为0,长度为4~16")
    private String market_mall_qq;
    @NotNull
    @Pattern(regexp = "\\d{3}-\\d{7,8}", message = "电话号码格式: xxx-7~8位")
    private String market_mall_phone;
    @NotNull
    private String market_mall_name;
}
